<script setup lang="ts">
import { defineProps } from 'vue'

interface ChatMsg {
  key: string
  role: 'ME' | 'AI'
  type: 'text'
  content: string
}

defineProps<{ item: ChatMsg }>()
</script>

<template>
  <div :class="['msg', item.role === 'ME' ? 'msg-to' : 'msg-from']">
    <div class="content">
      <div class="pao">{{ item.content }}</div>
    </div>
  </div>
</template>

<style lang="scss" scoped>
@use '@/styles/room.scss';
</style>
